//
//  ByApplyTitleTFView.m
//  caipiao_ios
//
//  Created by mc on 2018/10/8.
//  Copyright © 2018年 ZhangZhanbin. All rights reserved.
//

#import "ByApplyTitleTFView.h"

@implementation ByApplyTitleTFView

- (id)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        
        UIView *backgroundView = [[UIView alloc] initWithFrame:CGRectMake(0, 10, SCREEN_WIDTH, 49)];
        [self  addSubview:backgroundView];
        backgroundView.backgroundColor = [UIColor whiteColor];
        
        
        UILabel *titleLabel = [[UILabel alloc] init];
        [backgroundView addSubview:titleLabel];
        [titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.equalTo(backgroundView).offset(10);
            make.centerY.equalTo(backgroundView).offset(0);
            make.size.mas_equalTo(CGSizeMake(80, 20));
        }];
        
        titleLabel.font = FONT(13);
        titleLabel.textColor = BY_TEXT_COLOR;
        titleLabel.text = @"提现账号";
        titleLabel.backgroundColor = [UIColor whiteColor];
        self.titleLabel = titleLabel;
        
        
        UITextField *textField = [[UITextField alloc] init];
        [backgroundView addSubview:textField];
        [textField mas_makeConstraints:^(MASConstraintMaker *make) {
            make.centerY.equalTo(backgroundView).offset(0);
            make.left.equalTo(titleLabel.mas_right).offset(0);
            make.right.equalTo(backgroundView).offset(-10);
            make.height.mas_equalTo(@20);
        }];
        textField.placeholder = @"请输入账号";
        textField.font = FONT(14);
        textField.backgroundColor = [UIColor whiteColor];
        textField.textAlignment = NSTextAlignmentRight;
        self.textField = textField;
        
        
    }
    return self;
}

@end
